package com.hdax.dm.mapstrucs;

import com.hdax.dm.dto.TicketbuyerDto;
import com.hdax.dm.entity.user.DmLinkUser;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.Mappings;

import java.util.List;

@Mapper(componentModel = "spring")
public abstract class TicketbuyerDtoMapper {

    @Mappings({
            @Mapping(source = "id",target = "linkId")
    })
    public abstract TicketbuyerDto toTarget(DmLinkUser dmLinkUser);

    public abstract List<TicketbuyerDto> toTargets(List<DmLinkUser> dmLinkUsers);
}
